const JWT = require('jsonwebtoken');
const config = require('../config/getconfig.js');
const privateKey = config.JWT_SECRET;
class Jwtt{
    sign(data={},expiresIn='10h'){ 
       return JWT.sign(data, privateKey,{expiresIn});
    }
    verify(token){
        return JWT.verify(token,privateKey)
    }

}

module.exports =new Jwtt();